package may01ch13ex2;

public class MyInstanceOf {
	public static void main(String[] args) {

		Car[] cars = CarsFactory.getInstances();
		for (Car car : cars) {
			{
				System.out.println(car);
				System.out.println(car.getClass().getSuperclass()
						.getSuperclass().getSuperclass());
			}
		}
	}
}
// Object
// getClass (reflection)
// toString
// equals
// hashCode